<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<%@ page import="net.tribal.comic.entities.Comic" %>

<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
        <meta name="layout" content="main" />
        <title><g:message code="title.page.edit.nav"/></title>
    </head>
    
    <body>
	    <div class="navButtonsTop rounded-corners">
			<h1 class="title"><g:message code="title.user.edit.file" args="[pageInstance.alias]"/></h1>
		</div>
	        
	        <g:uploadForm>
		        <div class="element rounded-corners">
			        <g:hasErrors bean="${pageInstance}">
			        	<div class="errors rounded-corners"><g:renderErrors bean="${pageInstance}" as="list" /></div>
					</g:hasErrors>
				
					<div class="tableCreate">
						<table>
							<tbody>
								<tr>
									<td class="name">
										<label for="file"><g:message code="default.label.path"/>:</label>
									</td>
									<td class="value">
										<input type="file" name="file"/>
									</td>
								</tr>
							</tbody>
						</table>
					</div>
				</div>
				
				<div class="navButtons rounded-corners">
		    		<div class="left">
				        <g:actionSubmit class="save" action="updateFile" value="${message(code:'default.button.update')}" />
				        <g:actionSubmit class="delete" action="delete" value="${message(code:'default.button.delete')}" onclick="return confirm('${message(code: 'delete.confirm')}');" />
			    	</div>
			    	<div class="right">
	  					<g:actionSubmit class="show" action="show" value="${message(code:'default.button.back')}" />
  					</div>
			    </div>
			    
			    <g:hiddenField name="id" value="${comicInstance?.id}" />
				<g:hiddenField name="version" value="${comicInstance?.version}" />
			</g:uploadForm>
    </body>
</html>
